﻿@model ElectronicDiary.Models.Admin.ParentEditAddModel
@{
    ViewBag.Title = "Edycja Rodzica";
}

<h2>Edycja Rodzica</h2>

@Html.Action("Menu")

@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>Rodzic</legend>

        @Html.HiddenFor(model => model.UserId)

                <div class="editor-label">
            @Html.LabelFor(model => model.Login)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Login)
            @Html.ValidationMessageFor(model => model.Login)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.FName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.FName)
            @Html.ValidationMessageFor(model => model.FName)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.LName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.LName)
            @Html.ValidationMessageFor(model => model.LName)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Mail)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Mail)
            @Html.ValidationMessageFor(model => model.Mail)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.City)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.City)
            @Html.ValidationMessageFor(model => model.City)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.ZipCode)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.ZipCode)
            @Html.ValidationMessageFor(model => model.ZipCode)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.StreetName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.StreetName)
            @Html.ValidationMessageFor(model => model.StreetName)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Number)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Number)
            @Html.ValidationMessageFor(model => model.Number)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.ContactNumber)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.ContactNumber)
            @Html.ValidationMessageFor(model => model.ContactNumber)
        </div>
        <div class="editor-label">
            @Html.LabelFor(model => model.Active)
            @Html.CheckBoxFor(model => model.Active)
        </div>

        <p>
            <input type="submit" value="Zapisz" />
        </p>
    </fieldset>
}
    
<div>
    @Html.ActionLink("Powrót do listy", "ParentsView","Admin")
</div>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>